package com.jzo2o.customer.controller.worker;

import com.jzo2o.customer.model.dto.request.AgencyCertificationAuditAddReqDTO;
import com.jzo2o.customer.service.IAgencyCertificationService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

/**
 * @Description AgencyCertification
 * 机构端认证提交
 * @Author dmx
 * @Date 2024-12-03
 */
@RestController("agencyCertificationController")
@RequestMapping("/agency/agency-certification-audit")
@Api(tags = "机构端 - 提交认证接口")
public class AgencyCertificationController {

    @Autowired
    private IAgencyCertificationService agencyCertificationService;

    /**
     * 服务端提交认证申请
     * @param dto
     */
    @PostMapping
    @ApiOperation("机构端端提交认证申请")
    public void agencySubmitAAuthentication(@RequestBody AgencyCertificationAuditAddReqDTO dto){
        agencyCertificationService.agencySubmitAAuthentication(dto);
    }


    /**
     * 查询最新驳回原因
     * @return
     */
    @GetMapping("/rejectReason")
    @ApiOperation("机构端查询最新驳回原因")
    public Map<String,String> getRejectReason(){
        return agencyCertificationService.getRejectReason();
    }


}
